package com.wu.client.service;

import cn.hutool.core.collection.CollectionUtil;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.wu.client.constant.RelationShipTypeEnum;
import com.wu.mysql.entiy.ArtistDO;
import com.wu.mysql.entiy.RelationshipDO;


import java.util.List;
import java.util.stream.Collectors;


public interface RelationshipService extends IService<RelationshipDO> {
    Page<RelationshipDO> getPageInTargetIds(RelationShipTypeEnum relationShipTypeEnum, List<Long> targetIds, Integer page, Integer limit);
    Page<RelationshipDO> getPageInSourceIds(RelationShipTypeEnum relationShipTypeEnum,List<Long> sourceIds,Integer page,Integer limit);
    Page<RelationshipDO> getPageByTargetId(RelationShipTypeEnum relationShipTypeEnum,Long targetId,Integer page,Integer limit);
    Page<RelationshipDO> getPageBySourceId(RelationShipTypeEnum relationShipTypeEnum, Long sourceId,Integer page,Integer limit);

    List<RelationshipDO> getBySourceId(RelationShipTypeEnum relationShipTypeEnum,Long sourceId);
    List<RelationshipDO> getByTargetId(RelationShipTypeEnum relationShipTypeEnum,Long targetId);
    List<RelationshipDO> getInSourceId(RelationShipTypeEnum relationShipTypeEnum,List<Long> sourceIds);
    List<RelationshipDO> getInTargetId(RelationShipTypeEnum relationShipTypeEnum,List<Long> targetIds);

    String  getArtisName(Long resId, RelationShipTypeEnum relationShipTypeEnum);
    }

